
package com.tito.t_kulfonkup.fragments;

import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentTransaction;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;
import android.widget.Button;

import com.tito.t_kulfonkup.R;

public class Start extends Fragment implements OnClickListener {

    @Override
    public View onCreateView(LayoutInflater inflater,
            ViewGroup container, Bundle savedInstanceState) {

        View v = inflater.inflate(R.layout.start_layout, container, false);

        Button b = (Button) v.findViewById(R.id.btnStartRound);
        b.setOnClickListener(this);
        return v;

    }

    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.btnStartRound:
                Log.d("Kulfon", "Btn start pressed");
                FragmentTransaction ft = getFragmentManager().beginTransaction();
                ft.replace(R.id.fragment_container, new Play());
                ft.commit();
                break;
        }
    }

}
